<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<!-- 注意别各个属性值之间别漏了空格 -->
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<link href='./css/styles.css' type="text/css" rel="stylesheet" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script type="text/javascript" src="./js/jquery-1.7.2.js"></script>
<script type="text/javascript">
	function submit() {
		if(checkForm()){
			$("#loginAction").submit();
		}
	}
	function checkForm() {
		if ($("input[name='account']").val()!= ""
				&& $("input[name='password']").val()!= "") {
			return true;
		} else {
			alert("账号或者密码不得为空");
			return false;
		}

	}
</script>
<title>登陆</title>
</head>
<body>
	<div class="divOuterFrame">
		<div class="divInnerFrame">登陆页面</div>
	</div>
	<s:form action="user-login.action" theme="simple" id="loginAction">
		<s:debug></s:debug>
		账号:<s:textfield name="account" value=""></s:textfield>
		<br>
		密码:<s:password name="password" value=""></s:password>
		<br>
		<font color="red"><s:property value="loginFailure" /></font>&nbsp;&nbsp;&nbsp;<font color="blue"><s:property value="#request.loginFailure"  /></font> 
		<br>
		
		<%-- <s:submit value="登陆"></s:submit> --%><s:a href="javascript:submit()" >登陆</s:a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
		<s:a href="user-register.action">注册账号</s:a>
	</s:form>
</body>
</html>